{% extends 'main/elements/oneliner.html' %}

{% block related %}
	{% if oneliner.relateds %}
	{% with oneliner.relateds as alternatives %}
	<div class="related">
	    <h3 class="">Related one-liners</h3>
	    <div class="oneliners">
	    {% for alternative in alternatives %}
	    {% with alternative.oneliner as oneliner %}
	    {% include 'main/elements/oneliner.html' %}
	    {% endwith %}
	    {% endfor %}
	    </div>
	</div>
	{% endwith %}
	{% endif %}

	{% if oneliner.alternatives %}
	{% with oneliner.alternatives as alternatives %}
	<div class="related">
	    <h3 class="">Alternative one-liners</h3>
	    <div class="oneliners">
	    {% for alternative in alternatives %}
	    {% with alternative.alternative as oneliner %}
	    {% include 'main/elements/oneliner.html' %}
	    {% endwith %}
	    {% endfor %}
	    </div>
	</div>
	{% endwith %}
	{% endif %}

	{% if oneliner.questions %}
	{% with oneliner.questions as answers %}
	<div class="related">
	    <h3 class="">Related questions</h3>
	    <div class="questions">
	    {% for answer in answers %}
	    {% with answer.question as question %}
	    {% include 'main/elements/question.html' %}
	    {% endwith %}
	    {% endfor %}
	    </div>
	</div>
	{% endwith %}
	{% endif %}
{% endblock %}
